<template>
  <div class="test-button" @click="emit('customEvent')">
    我是一个按钮组件
  </div>
</template>

<script setup lang="ts">
const emit = defineEmits<{
  (e: 'customEvent'): void
}>();
</script>

<style scoped>
.test-button {
  display: inline-block;
  background: #4788e8;
  padding: 5px 10px;
  border-radius: 5px;
  color: #fff;
}
</style>
